package com.hiep.connect.client.event;

import com.google.gwt.event.shared.GwtEvent;
import com.hiep.connect.shared.MyUser;

public class UserLogoutEvent extends GwtEvent<UserLogoutEventHandler> {
	public static Type<UserLogoutEventHandler> TYPE = new Type<UserLogoutEventHandler>();
	private final MyUser user;

	public MyUser getUser() {
		return user;
	}

	public UserLogoutEvent(MyUser user) {
		this.user = user;
	}

	@Override
	public Type<UserLogoutEventHandler> getAssociatedType() {
		return TYPE;
	}

	@Override
	protected void dispatch(UserLogoutEventHandler handler) {
		handler.onUserLogout(this);
	}
}
